<%@ taglib prefix="s" uri="/struts-tags" %>
<link rel="stylesheet" type="text/css" href="/kbond/css/custom.css" />
<style>
<!--
.require {
    padding-left: 10px;
    /* color: #f00; */
    font-weight: bold;
    font-size: 20px;
}

-->
</style>
<!-- BODY -->
<div >
    <div>
        <div >
        <table width="100%">
        	<tr>
        		<td align="center">
        			<table>
        				<tr height="295">
        					<td width="570" valign="top" align="left"  background="/kbond/images/handleException.jpg" class="errorFont2" >
        						<div class="errorFont1" style="padding: 20pt;">
        							<table>
        								<tr>
        								 	<td>
        										<img src="/kbond/images/error.gif"></div>
        								 	</td>
        								 	<td valign="middle">
        								 		 Application Error. (Can not Connect to Server, please try again later.)
        								 	</td>
        								</tr>
        							</table>
        						</div>
        						<div class="errorFont2" style="padding-left: 20pt">An error has occurred.Technical details for support personnel are provided below.</div>
        						<div class="errorFont2" style="padding-left: 20pt">Please try one of the following options:</div>
        						<br>
        						<br>
        						<div class="errorFont2" style="padding-left: 20pt"><a href="#" onclick="window.location.reload(false)">Refresh current screen</a></div>
        						<br><div class="errorFont2" style="padding-left: 20pt"><a href="/kbond" >Home page</a></div>
        						<br><div class="errorFont2" style="padding-left: 20pt"><a href="/kbond/logout.action">Logout</a></div>
        					</td>
        				</tr>
        			</table>
        		</td>
        	</tr>
        </table>
        </div>
    </div>
</div>
<div><a href="#" onclick="openDetailError()">Detail Error</a>
</div>
<div id="errorP" style="display: none;">
<h2>An unexpected error has occurred</h2>
  <p>
    Please report this error to your system administrator
    or appropriate technical support personnel.
    Thank you for your cooperation.
  </p>
  
  <hr/>
  <h3>Error Message</h3>
    <s:actionerror/>
    <p>
      <s:property value="%{exception.message}"/>
    </p>
    <hr/>
    <h3>Technical Details</h3>
    <p>
      <s:property value="%{exceptionStack}" id="errorDecs"/>
      <% System.out.println(request.getAttribute("exceptionStack").toString()); %>
    </p>
</div>
<script type="text/javascript">
var mode = 0;
function openDetailError(){
	if(mode == 0){
		document.getElementById("errorP").style.display = '';
		mode = 1;
	}else {
		mode = 0;
		document.getElementById("errorP").style.display = 'none';
	}
}
</script>